package com.uwaterloo.interviewme.requsthandler;

import java.util.Collection;

import com.uwaterloo.interviewme.exception.ServerException;
import com.uwaterloo.interviewme.model.DetailInfo;
import com.uwaterloo.interviewme.model.Interview;

/**
 * The Class RequestHandler.
 */
public abstract class RequestHandler {
	/**
	 * Login.
	 *
	 * @param user the user
	 * @param pwd the pwd
	 * @return true, if successful
	 */
	public abstract boolean login(String user, String pwd) throws ServerException;
	
	/**
	 * Gets the all interview.
	 *
	 * @param user the user
	 * @return the all interview
	 */
	public abstract Collection<Interview> getAllInterview(String user) throws ServerException;
	
	/**
	 * Gets the one interview.
	 *
	 * @param user the user
	 * @param interviewID the interview id
	 * @return the one interview
	 */
	public abstract DetailInfo getOneInterview(String user, String interviewID) throws ServerException;
	
	/**
	 * Sets the sync interval.
	 *
	 * @param user the user
	 * @param interval the interval
	 */
	public abstract void setSyncInterval(String user, int interval) throws ServerException;
}